<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Map</title>
</head>
    <h1>Map</h1>
    <li>
        Size 返回Map的元素个数
    </li>
    <li>
       Set 添加一个新元素，返回当前Map
    </li>
    <li>
       Get 返回键名对象的键值
    </li>
    <li>
        has 检查Map中是否包含某个元素，返回Boolean值。
    </li>
    <li>
        Clear 清空集合。
    </li>
    </body>
    <script>
        let m = new Map();

        m.set("name","实习生");
        m.set("change",function(){
            console.log("我要改变你");
        })

        let abc = {
            school:"湘北"
        };
        m.set(abc,["樱木花道","流川枫","宫城良田","赤木刚宪","三井寿"]);

        console.log(m);
        console.log(m.size);
        m.delete(abc);
        console.log(m);
        console.log(m.get("name"));
        for(let v of m){
            console.log(m);
        }
        m.clear();
        
    </script>
</html>